package org.lem

class ScheduledClass {

  Location location
  ClassDay classDays
  ClassTime classTime
  SkillLevel skillLevel
  ClassSession session
  String inputBy
  Date inputDate

  static constraints = {
    location()
    classDays()
    classTime()
    skillLevel()
    session(nullable: true)
    inputBy()
    inputDate()
  }

  String toString() {
    def toStringVal =  "${location} ${classDays} ${classTime} ${skillLevel}"

    if(null != session){
      toStringVal += " ${session}"
    }
    
    return toStringVal
  }
}
